import { ApiProperty } from '@nestjs/swagger';
import { PrimaryGeneratedColumn, Column, Entity } from 'typeorm';
import { BaseEntity } from '../base.entity';

@Entity({ name: 'sys_test' })
export default class SysTest extends BaseEntity {
  // ID自增的  //并且生成一个uuid
  @PrimaryGeneratedColumn()
  @ApiProperty({ example: '18888888888' })
  id: number;
 
  // unique 表示当前数据不能重复
  @Column({ type: 'varchar', length: 50, unique: true })
  // @ApiProperty()
  key: string;

  @Column({ type: 'varchar', length: 50 })
  // @ApiProperty()
  name: string;

  @Column({ type: 'varchar', nullable: true })
  // @ApiProperty()
  value: string;

  @Column({ type: 'varchar', nullable: true })
  // @ApiProperty()
  remark: string;
}
